/* ticket */

#ifndef TICKET_H_
#define TICKET_H_


#define NO_TICKET -1
#define LACK_TICKET -2


typedef struct ticket{
	int id;
	char trainno[8];
	time_t time;
	int num;
	char description[256];
} ticket_t;

typedef struct ticket_collection{
	ticket_t *tickets;
	int len;
} ticket_collection_t;

ticket_collection_t *ticket_collection_open(const char *path);

int ticket_collection_close(ticket_collection_t * tc);



#endif /* TICKET_H_ */
